{// 引入标签库 }

<tagLib name="fanwe" />

<include file="Public:header" />

<load href="__TMPL__ThemeFiles/Js/jquery.js" />

<load href="__TMPL__ThemeFiles/Js/tabs.js" />

<load href="__TMPL__ThemeFiles/Js/site.js" />

<load href="__TMPL__ThemeFiles/Js/model.js" />

<load href="__TMPL__ThemeFiles/Js/iColorPicker.js" />

<div id="main" class="main">

<div class="content">

<div class="title">{$Think.lang.ADD_DATA} [ <a href="{:u($module_name.'/index')}">{$Think.lang.BACK_LIST}</a> ]</div>

<div id="result" class="result none"></div>

<form method='post' id="form" name="form" action="{:u($module_name.'/update')}" enctype="multipart/form-data">

<ul class="conf_btns">
	<li>{$Think.lang.TAB_SITE}</li>
	<li>{$Think.lang.TAB_SITE_CITY}</li>
	<li>{$Think.lang.TAB_COLLECT_URL}</li>
	<li>{$Think.lang.TAB_COLLECT_GOODS}</li>
</ul>

<div class="conf_tabs">

<table cellpadding=0 cellspacing=0 class="conf_table dataEdit" >

	<tr>

		<td class="tRight" width="120">{$Think.lang.NAME}：</td>

		<td class="tLeft">

        	<input type="text" name="name" id="name" class="bLeftRequire iColorPicker" rel="name_color" value="{$vo.name}" <if condition="$vo['name_color']">style="color:{$vo.name_color}"</if> />

            <input type="hidden" id="name_color" name="name_color" value="{$vo.name_color}" />

            <select name="name_style">

              <option value="">字体样式</option>

              <option value="strong" <if condition="$vo['name_style'] eq 'strong'">selected</if>>加粗</option>

              <option value="em" <if condition="$vo['name_style'] eq 'em'">selected</if>>斜体</option>

              <option value="u" <if condition="$vo['name_style'] eq 'u'">selected</if>>下划线</option>

              <option value="strike" <if condition="$vo['name_style'] eq 'strike'">selected</if>>删除线</option>

            </select>

        </td>

	</tr>
	<tr>
		<td class="tRight" width="120">团购站管理员：</td>
		<td class="tLeft">
			<select id="user_id" name="user_id">
				<if condition='$user'>
				<option value="{$user.uid}">{$user.user_name}</option>
				<else/>
				<option value="0">=={$Think.lang.SELECT}==</option>
				</if>
			</select>
			<input type="text" id="userKey" class="site-key" style="width:80px;" value="" />&nbsp;
			<input type="button" class="search-site" value="{$Think.lang._SEARCH_DATA}" style="cursor:pointer;" onclick="$.searchUser('#userKey','#user_id',1);" />
		</td>
	</tr>
	<tr>

		<td class="tRight" width="120">{$Think.lang.CATEID}：</td>

		<td class="tLeft">

			<select name="cate_id">

				<foreach name="cateList" item="cateItem">

				<option value="{$cateItem.id}" <if condition="$cateItem['id'] eq $vo['cate_id']">selected</if>>{$cateItem.name}</option>

				</foreach>

			</select>

		</td>

	</tr>
    <tr>
        <td class="tRight" width="120">推荐：</td>
        <td class="tLeft">
          <label><input type="radio" name="is_best" value="1" <if condition="1 eq $vo['is_best']">checked</if>/>是</label>
          <label><input type="radio" name="is_best" value="0" <if condition="0 eq $vo['is_best']">checked</if>/>否</label>			
        </td>
    </tr>
    <tr>
        <td class="tRight" width="120">认证：</td>

        <td class="tLeft">

          <label><input type="radio" name="is_auth" value="1" <if condition="1 eq $vo['is_auth']">checked</if>/>是</label>

          <label><input type="radio" name="is_auth" value="0" <if condition="0 eq $vo['is_auth']">checked</if>/>否</label>			

        </td>

    </tr>

    <tr>

		<td class="tRight" width="120">{$Think.lang.KEY}：</td>

		<td class="tLeft">

			<input type="text" name="site_key" id="site_key" class="bLeftRequire" value="{$vo.site_key}" />&nbsp;<span style="color:#f00; display:none" id="key-exists">{$Think.lang.KEY_EXISTS}</span>

		</td>

	</tr>

	<!--<tr>

		<td class="tRight" width="120">会员邀请码：</td>

		<td class="tLeft">

			<input type="text" name="invite_key" id="invite_key" class="bLeft" value="{$vo.invite_key}"/>&nbsp;用于获取会员邀请的返利，格式请参照下面例子<span style="color:#f00;">红色部分</span>，此设置针对站点下发布的所有商品

		</td>

	</tr>

	<tr>

		<td class="tRight" width="120">识别码/邀请码插<br/>入位置([CODE])：</td>

		<td class="tLeft">

			<input type="text" name="code_position" id="code_position" class="bLeft" value="{$vo.code_position}"/>&nbsp;格式请参照下面例子<span style="color:#00f;">蓝色部分</span>

		</td>

	</tr>
	
	<tr>

		<td class="tLeft" colspan="2">

			例：团购链接为 http://www.futuan.com/tg-232.html　格式为 <span style="color:#f00">-key-value</span>　插入位置为 <span style="color:#00f">*[CODE].html</span><br/>

			　　团购链接为 http://www.futuan.com/goods.php?id=232　格式为 <span style="color:#f00">&key=value</span>　插入位置为 <span style="color:#00f">*[CODE]</span><br/>

			　　团购链接为 http://www.futuan.com/goods/id/232/　格式为 <span style="color:#f00">key/value/</span>　插入位置为 <span style="color:#00f">*[CODE]</span>

		</td>

	</tr>-->
	
	<tr>
		<td class="tRight" width="120">团购邀请URL：</td>
		<td class="tLeft">
			<input type="text" name="invite_url" id="invite_url" class="bLeft" value="{$vo.invite_url}"/>&nbsp;
			<span style="color:#f00;">此设置针对站点下发布的所有商品，团购和站点跳转时将使用此URL</span>
		</td>
	</tr>
	<tr>
		<td class="tRight" width="120">站点CPS前缀：</td>
		<td class="tLeft">
			<input type="text" name="cps_url" id="cps_url" class="bLeft" value="{$vo.cps_url}"/>&nbsp;
			<span style="color:#f00;">此设置针对站点下发布的所有商品，团购跳转时估先将使用此设置</span>
		</td>
	</tr>
	<tr>

		<td class="tRight" width="120">{$Think.lang.URL}：</td>

		<td class="tLeft"><fanwe:textbox name="url" class="bLeftRequire" /></td>

	</tr>

	<tr>

		<td class="tRight">{$Think.lang.SORT}：</td>

		<td class="tLeft"><input type="text" value="{$vo.sort}" name="sort" /></td>

	</tr>
    <if condition="$vo['site_img']">
    <tr>
		<td rowspan="2" class="tRight">网站截图：</td>
		<td class="tLeft"><img src="{$vo.site_img}" height="150" /></td>
	</tr>
    <tr>
        <td class="tLeft"><input type="file" name="site_img" size="30"/></td>
    </tr>
    <else/>
    <tr>
		<td class="tRight">网站截图：</td>
		<td class="tLeft"><input type="file" name="site_img"  size="30"/></td>
	</tr>
    </if>
	<tr>

		<td class="tRight">网站描述：</td>

		<td class="tLeft"><fanwe:editor name="content" type="KindEditor"  style="width:650px;height:200px;visibility:hidden;" />				</td>

	</tr>

</table>
<table cellpadding=0 cellspacing=0 class="conf_table dataEdit" >
	<tr>
        <td class="tLeft">
			<div style="height:26px; line-height:26px; color:#f00; padding:0 8px;">
				如果网站不属于该城市请保留为空，如果网站属于全国，请勾选全国复选框&nbsp;
				<input type="checkbox" name="is_all" id="is_all_city" value="1" <if condition="$vo['is_all'] eq 1">checked</if> />&nbsp;是否全国
			</div>
         	<div id="city_list">
				<foreach name="site_citys" key="sc_py" item="sc_list">
                <dl style="width:100%; float:left; padding:0 8px;margin:0;">
					<dt style="width:100%; float:left; padding:0;margin:0; font-weight:bold; font-size:14px;">{$sc_py}</dt>
					<dd style="width:100%; float:left; padding:10px 0 0 0; margin:0;">
					<foreach name="sc_list" item="sc_item">
						<p style="width:60px; float:left; margin:0 8px 8px 0;">
							{$sc_item.name}<br/>
							<input type="text" class="site_city" value="{$sc_item.sort}" name="city_site[{$sc_item.id}]" sort="{$sc_item.sort}" style="width:50px;<if condition="$sc_item['sort'] neq ''">border:solid 1px #f30;</if>" <if condition="$vo['is_all'] eq 1">disabled</if> \/>
						</p>
					</foreach>
					 </dd>
				</dl>
				</foreach>	
		</div>
        </td>
    </tr>
</table>
<table cellpadding=0 cellspacing=0 class="conf_table dataEdit" >

	<tr>

        <td class="tRight" width="180">禁用采集：</td>

        <td class="tLeft">

          <label><input type="radio" name="close_collect" value="1" <if condition="1 eq $vo['close_collect']">checked</if>/>是</label>

          <label><input type="radio" name="close_collect" value="0" <if condition="0 eq $vo['close_collect']">checked</if>/>否</label>			

        </td>

    </tr>

    <tr>

		<td class="tRight" width="180">{$Think.lang.COLLECT_URL}：</td>

		<td class="tLeft"><input type="text" name="collect_url" value='{$siteRules.collect_url}' size="60" /></td>

	</tr>

	<tr>

		<td class="tRight" width="180">{$Think.lang.COLLECT_CODE}：</td>

		<td class="tLeft">

			<label><input type="radio" name="collect_code" value="UTF-8" <if condition="$siteRules.collect_code eq 'UTF-8'">checked</if>/>{$Think.lang.COLLECT_CODE_0}</label>

			<label><input type="radio" name="collect_code" value="GBK" <if condition="$siteRules.collect_code eq 'GBK'">checked</if>/>{$Think.lang.COLLECT_CODE_1}</label>

			<label><input type="radio" name="collect_code" value="BIG-5" <if condition="$siteRules.collect_code eq 'BIG-5'">checked</if>/>{$Think.lang.COLLECT_CODE_2}</label>

		</td>

	</tr>

	<tr>

		<td class="tRight">{$Think.lang.COLLECT_TYPE}：</td>

		<td class="tLeft collect_type">

			<label><input type="radio" name="collect_type" value="1" <if condition="$siteRules.collect_type eq 1">checked</if>/>{$Think.lang.COLLECT_TYPE_0}</label>

			<label><input type="radio" name="collect_type" value="2" <if condition="$siteRules.collect_type eq 2">checked</if>/>{$Think.lang.COLLECT_TYPE_1}</label>

		</td>

	</tr>

	<tr>

		<td class="tRight">{$Think.lang.WEB_TYPE}：</td>

		<td class="tLeft web_type">

			<label><input type="radio" name="web_type" value="1" <if condition="$siteRules.web_type eq 1">checked</if>/>{$Think.lang.WEB_TYPE_0}</label>

			<label><input type="radio" name="web_type" value="2" <if condition="$siteRules.web_type eq 2">checked</if>/>{$Think.lang.WEB_TYPE_1}</label>

		</td>

	</tr>

	<!-- 网页方式 -->

	<tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.CITY_EXTENT}：</td>

		<td class="tLeft"><textarea name="web[city_extent]" style="width: 80%; height: 80px;">{$siteRules.city_extent}</textarea></td>

	</tr>

	<tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.CITY_URL_RULE}：</td>

		<td class="tLeft"><textarea name="web[city_url_rule]" style="width: 80%; height: 80px;">{$siteRules.city_url_rule}</textarea></td>

	</tr>

    <tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.CITY_URL_EXT}：</td>

		<td class="tLeft"><input type="text" name="web[city_url_ext]" style="width: 80%;" value='{$siteRules.city_url_ext}'/></td>

	</tr>

    <tr class="multi_city collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.CITY_NAME_RULE}：</td>

		<td class="tLeft"><textarea name="web[city_name_rule]" style="width: 80%; height: 80px;">{$siteRules.city_name_rule}</textarea></td>

	</tr>

    <tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.CITY_NAME_EXT}：</td>

		<td class="tLeft"><input type="text" name="web[city_name_ext]" style="width: 80%;" value='{$siteRules.city_name_ext}'/></td>

	</tr>

    <tr class="multi_city collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.MANUAL_URL_NAME}：</td>

		<td class="tLeft">

			<textarea name="web[munual_url_name]" style="width: 80%; height: 80px;">{$siteRules.munual_url_name}</textarea>

			<div class="red">

				{$Think.lang.MANUAL_URL_NAME_NOTICE}

			</div>

		</td>

	</tr>

	<!--<tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.IS_COLLECT_GOODS_URL}：</td>

		<td class="tLeft web_type">

			<label><input type="radio" name="web[is_collect_goods_url]" value="1" <if condition="$siteRules.is_collect_goods_url eq 1">checked</if>/>{$Think.lang.IS_COLLECT_GOODS_URL_1}</label>

			<label><input type="radio" name="web[is_collect_goods_url]" value="2" <if condition="$siteRules.is_collect_goods_url eq 2">checked</if>/>{$Think.lang.IS_COLLECT_GOODS_URL_2}</label>

		</td>

	</tr>

	<tr class="multi_city collect_type_0">

		<td class="tRight">{$Think.lang.GOODS_URL_RULE}：</td>

		<td class="tLeft"><textarea name="web[goods_url_rule]" style="width: 80%; height: 80px;">{$siteRules.goods_url_rule}</textarea></td>

	</tr>-->

	<!-- 接口方式 -->

    <tr class="collect_type_1 none">

        <td class="tRight" width="180">API接口类型：</td>

        <td class="tLeft">

          	<select name="rule_type" id="rule_type" >

            <option value="0">不设置</option>

            <foreach name="ruleType" item="rt_item">

            <option value="{$rt_item.id}" <if condition="$rt_item['id'] eq $vo['rule_type']">selected</if>>{$rt_item.name}</option>

            </foreach>

            </select>		

             <span style="color:#f00;">&nbsp;（注意：设置类型后，将会覆盖以前的设置）</span>			

        </td>

    </tr>

	<tr class="multi_city collect_type_1 none">

		<td class="tRight">{$Think.lang.CITY_ARRAY}：</td>

		<td class="tLeft"><input type="text" name="api[city_array]" id="city_array" size="60" value='{$siteRules.city_array}' /></td>

	</tr>

	<tr class="multi_city collect_type_1 none">

		<td class="tRight">{$Think.lang.CITY_URL_API}：</td>

		<td class="tLeft"><input type="text" name="api[city_url_api]" id="city_url_api" size="60" value='{$siteRules.city_url_api}' /></td>

	</tr>

	<tr class="multi_city collect_type_1 none">

		<td class="tRight">{$Think.lang.CITY_NAME_API}：</td>

		<td class="tLeft"><input type="text" name="api[city_name_api]" id="city_name_api" size="60" value='{$siteRules.city_name_api}' /></td>

	</tr>

	<tr class="multi_city collect_type_1 none">

		<td class="tRight">{$Think.lang.MANUAL_URL_NAME_API}：</td>

		<td class="tLeft">

			<textarea name="api[munual_url_name_api]" style="width: 80%; height: 80px;">{$siteRules.munual_url_name_api}</textarea>

			<div class="red">

				{$Think.lang.MANUAL_URL_NAME_NOTICE}

			</div>

		</td>

	</tr>

    <tr class="collect_city_api">

		<td class="tRight">采集城市名称：</td>

		<td class="tLeft">

			<textarea name="collect_city_api" style="width: 80%; height: 80px;">{$siteRules.collect_city_api}</textarea>

			<div class="red">

				以,号分隔，设置后将只采集等于所设城市名称的团购城市；为空采集所有城市。

			</div>

		</td>

	</tr>

</table>

<table cellpadding=0 cellspacing=0 class="conf_table dataEdit" >

	<!-- 网页方式 -->

	<tr class="collect_type_0 none">

		<td class="tRight">标识码(GROUP_KEY)：</td>

		<td class="tLeft"><textarea name="web[group_key_rule]" style="width: 80%; height: 80px;">{$siteRules.group_key_rule}</textarea></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">标识码扩展公式：</td>

		<td class="tLeft"><input type="text" name="web[group_key_ext]" style="width: 80%;" value='{$siteRules.group_key_ext}' /></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">&nbsp;</td>

		<td class="tLeft">

        	用于采集上传时，检测重复团购

        </td>

	</tr>

    <tr class="collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight" width="200">{$Think.lang.GROUP_NMAE_RULE}：</td>

		<td class="tLeft"><textarea name="web[group_name_rule]" style="width: 80%; height: 80px;">{$siteRules.group_name_rule}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_NMAE_EXT}：</td>

		<td class="tLeft"><input type="text" name="web[group_name_ext]" style="width: 80%;" value='{$siteRules.group_name_ext}'/></td>

	</tr>

    <tr class="collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_IMAGE_RULE}：</td>

		<td class="tLeft"><textarea name="web[group_image_rule]" style="width: 80%; height: 80px;">{$siteRules.group_image_rule}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_IMAGE_EXT}：</td>

		<td class="tLeft"><input type="text" name="web[group_image_ext]" style="width: 80%;" value='{$siteRules.group_image_ext}'/></td>

	</tr>

    <tr class="collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_END_TIME_RULE}：</td>

		<td class="tLeft"><textarea name="web[group_end_time_rule]" style="width: 80%; height: 80px;">{$siteRules.group_end_time_rule}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_END_TIME_RULE1}：</td>

		<td class="tLeft"><textarea name="web[group_end_time_rule1]" style="width: 80%; height: 80px;">{$siteRules.group_end_time_rule1}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">

        	{$Think.lang.GROUP_END_TIME_EXT}：<br/>

        	{$Think.lang.GET_NOW_TIME}

        </td>

		<td class="tLeft"><input type="text" name="web[group_end_time_ext]" style="width: 80%;" value='{$siteRules.group_end_time_ext}'/></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">{$Think.lang.SET_TIME_ZONE}：</td>

		<td class="tLeft">

        <select name="web[group_end_time_zone]" >

        	<option value="0">(GMT 0:00) UTC {$Think.lang.NOT_SET_TIME_ZONE}</option>

        	<option value="8" <if condition="$siteRules.group_end_time_zone eq 8">selected</if>>(GMT +08:00) 北京,香港,珀斯,新加坡,台北</option>

            <option value="-12" <if condition="$siteRules.group_end_time_zone eq -12">selected</if>>GMT -12:00) Eniwetok, Kwajalein</option>

            <option value="-11" <if condition="$siteRules.group_end_time_zone eq -11">selected</if>>(GMT -11:00) Midway Island, Samoa</option>

            <option value="-10" <if condition="$siteRules.group_end_time_zone eq -10">selected</if>>(GMT -10:00) Hawaii</option>

            <option value="-9" <if condition="$siteRules.group_end_time_zone eq -9">selected</if>>(GMT -09:00) Alaska</option>

            <option value="-8" <if condition="$siteRules.group_end_time_zone eq -8">selected</if>>(GMT -08:00) Pacific Time (US &amp; Canada), Tijuana</option>

            <option value="-7" <if condition="$siteRules.group_end_time_zone eq -7">selected</if>>(GMT -07:00) Mountain Time (US &amp; Canada), Arizona</option>

            <option value="-6" <if condition="$siteRules.group_end_time_zone eq -6">selected</if>>(GMT -06:00) Central Time (US &amp; Canada), Mexico City</option>

            <option value="-5" <if condition="$siteRules.group_end_time_zone eq -5">selected</if>>(GMT -05:00) Eastern Time (US &amp; Canada), Bogota, Lima, Quito</option>

            <option value="-4" <if condition="$siteRules.group_end_time_zone eq -4">selected</if>>(GMT -04:00) Atlantic Time (Canada), Caracas, La Paz</option>

            <option value="-3.5" <if condition="$siteRules.group_end_time_zone eq -3.5">selected</if>>(GMT -03:30) Newfoundland</option>

            <option value="-3" <if condition="$siteRules.group_end_time_zone eq -3">selected</if>>(GMT -03:00) Brassila, Buenos Aires, Georgetown, Falkland Is</option>

            <option value="-2" <if condition="$siteRules.group_end_time_zone eq -2">selected</if>>(GMT -02:00) Mid-Atlantic, Ascension Is., St. Helena</option>

            <option value="-1" <if condition="$siteRules.group_end_time_zone eq -1">selected</if>>(GMT -01:00) Azores, Cape Verde Islands</option>

            <option value="1" <if condition="$siteRules.group_end_time_zone eq 1">selected</if>>(GMT +01:00) Amsterdam, Berlin, Brussels, Madrid, Paris, Rome</option>

            <option value="2" <if condition="$siteRules.group_end_time_zone eq 2">selected</if>>(GMT +02:00) Cairo, Helsinki, Kaliningrad, South Africa</option>

            <option value="3" <if condition="$siteRules.group_end_time_zone eq 3">selected</if>>(GMT +03:00) Baghdad, Riyadh, Moscow, Nairobi</option>

            <option value="3.5" <if condition="$siteRules.group_end_time_zone eq 3.5">selected</if>>(GMT +03:30) Tehran</option>

            <option value="4" <if condition="$siteRules.group_end_time_zone eq 4">selected</if>>(GMT +04:00) Abu Dhabi, Baku, Muscat, Tbilisi</option>

            <option value="4.5" <if condition="$siteRules.group_end_time_zone eq 4.5">selected</if>>(GMT +04:30) Kabul</option>

            <option value="5" <if condition="$siteRules.group_end_time_zone eq 5">selected</if>>(GMT +05:00) Ekaterinburg, Islamabad, Karachi, Tashkent</option>

            <option value="5.5" <if condition="$siteRules.group_end_time_zone eq 5.5">selected</if>>(GMT +05:30) Bombay, Calcutta, Madras, New Delhi</option>

            <option value="5.75" <if condition="$siteRules.group_end_time_zone eq 5.75">selected</if>>(GMT +05:45) Katmandu</option>

            <option value="6" <if condition="$siteRules.group_end_time_zone eq 6">selected</if>>(GMT +06:00) Almaty, Colombo, Dhaka, Novosibirsk</option>

            <option value="6.5" <if condition="$siteRules.group_end_time_zone eq 6.5">selected</if>>(GMT +06:30) Rangoon</option>

            <option value="7" <if condition="$siteRules.group_end_time_zone eq 7">selected</if>>(GMT +07:00) Bangkok, Hanoi, Jakarta</option>

            <option value="9" <if condition="$siteRules.group_end_time_zone eq 9">selected</if>>(GMT +09:00) Osaka, Sapporo, Seoul, Tokyo, Yakutsk</option>

            <option value="9.5" <if condition="$siteRules.group_end_time_zone eq 9.5">selected</if>>(GMT +09:30) Adelaide, Darwin</option>

            <option value="10" <if condition="$siteRules.group_end_time_zone eq 10">selected</if>>(GMT +10:00) Canberra, Guam, Melbourne, Sydney, Vladivostok</option>

            <option value="11" <if condition="$siteRules.group_end_time_zone eq 11">selected</if>>(GMT +11:00) Magadan, New Caledonia, Solomon Islands</option>

            <option value="12" <if condition="$siteRules.group_end_time_zone eq 12">selected</if>>(GMT +12:00) Auckland, Wellington, Fiji, Marshall Island</option>

        </select>

        </td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">&nbsp;</td>

		<td class="tLeft">

        	{$Think.lang.TIME_ZONE_NOTIC}

        </td>

	</tr>

    <tr class="collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_SHOP_PRICE_RULE}：</td>

		<td class="tLeft"><textarea name="web[group_shop_price_rule]" style="width: 80%; height: 80px;">{$siteRules.group_shop_price_rule}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_SHOP_PRICE_EXT}：</td>

		<td class="tLeft"><input type="text" name="web[group_shop_price_ext]" style="width: 80%;" value='{$siteRules.group_shop_price_ext}'/></td>

	</tr>

    <tr class="collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_MARKET_PRICE_RULE}：</td>

		<td class="tLeft"><textarea name="web[group_market_price_rule]" style="width: 80%; height: 80px;">{$siteRules.group_market_price_rule}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">{$Think.lang.GROUP_MARKET_PRICE_EXT}：</td>

		<td class="tLeft"><input type="text" name="web[group_market_price_ext]" style="width: 80%;" value='{$siteRules.group_market_price_ext}'/></td>

	</tr>

	<tr class="collect_type_0">

		<td colspan="2"><hr/></td>

	</tr>

	<tr class="collect_type_0">

		<td class="tRight">已购买人数(BOUGHT)：</td>

		<td class="tLeft"><textarea name="web[group_bought_rule]" style="width: 80%; height: 80px;">{$siteRules.group_bought_rule}</textarea></td>

	</tr>

    <tr class="collect_type_0">

		<td class="tRight">已购买人数扩展公式：</td>

		<td class="tLeft"><input type="text" name="web[group_bought_ext]" style="width: 80%;" value='{$siteRules.group_bought_ext}'/></td>

	</tr>

	<!-- 接口方式 -->

	<tr class="collect_type_1 none">

		<td class="tRight" width="180">{$Think.lang.GROUP_OBJECT_API}：</td>

		<td class="tLeft"><input type="text" name="api[group_object_api]" id="group_object_api" size="60" value='{$siteRules.group_object_api}' /></td>

	</tr>

	<tr class="collect_type_1 none">

		<td class="tRight">标识码(GOODS.*)：</td>

		<td class="tLeft"><input type="text" name="api[group_key_api]" id="group_key_api" size="60" value='{$siteRules.group_key_api}'/></td>

	</tr>

	<tr class="collect_type_1 none">

		<td class="tRight">&nbsp;</td>

		<td class="tLeft">

        	用于采集上传时，检测重复团购

        </td>

	</tr>

    <tr class="collect_type_1 none">

		<td class="tRight" width="180">团购城市(GOODS.*)：</td>

		<td class="tLeft"><input type="text" name="api[group_city_api]" id="group_city_api" size="60" value='{$siteRules.group_city_api}' /></td>

	</tr>
	
	<tr class="collect_type_1 none">

		<td class="tRight" width="180">团购权重(GOODS.*)：</td>

		<td class="tLeft"><input type="text" name="api[group_sort_api]" id="group_sort_api" size="60" value='{$siteRules.group_sort_api}' /></td>

	</tr>

	<tr class="collect_type_1 none">

		<td class="tRight" width="180">{$Think.lang.GROUP_URL_API}：</td>

		<td class="tLeft"><input type="text" name="api[group_url_api]" id="group_url_api" size="60" value='{$siteRules.group_url_api}' /></td>

	</tr>

	<tr class="collect_type_1 none">

		<td class="tRight" width="180">{$Think.lang.GROUP_NMAE_API}：</td>

		<td class="tLeft"><input type="text" name="api[group_name_api]" id="group_name_api" size="60" value='{$siteRules.group_name_api}' /></td>

	</tr>

	<tr class="collect_type_1 none">

		<td class="tRight">{$Think.lang.GROUP_IMAGE_API}：</td>

		<td class="tLeft"><input type="text" name="api[group_image_api]" id="group_image_api" size="60" value='{$siteRules.group_image_api}' /></td>

	</tr>
	<tr class="collect_type_1 none">
		<td class="tRight">
        	团购开始时间(GOODS.*)：
        </td>
		<td class="tLeft"><input type="text" name="api[group_begin_time_api]" id="group_begin_time_api" size="60" value='{$siteRules.group_begin_time_api}' /></td>
	</tr>
	<tr class="collect_type_1 none">

		<td class="tRight">

        	{$Think.lang.GROUP_END_TIME_API}：<br/>

        	

        </td>

		<td class="tLeft"><input type="text" name="api[group_end_time_api]" id="group_end_time_api" size="60" value='{$siteRules.group_end_time_api}' /></td>

	</tr>

    <tr class="collect_type_1 none">

		<td class="tRight">

        	{$Think.lang.GROUP_END_TIME_EXT_API}<br/>

        	{$Think.lang.GET_NOW_TIME}</td>

		<td class="tLeft"><input type="text" name="api[group_end_time_ext_api]" id="group_end_time_ext_api" size="60" value='{$siteRules.group_end_time_ext_api}'/></td>

	</tr>

    <tr class="collect_type_1 none">

		<td class="tRight">{$Think.lang.SET_TIME_ZONE}：</td>

		<td class="tLeft">

        <select name="api[group_end_time_zone_api]" id="group_end_time_zone_api">

        	<option value="0">(GMT 0:00) UTC {$Think.lang.NOT_SET_TIME_ZONE}</option>

        	<option value="8" <if condition="$siteRules.group_end_time_zone_api eq 8">selected</if>>(GMT +08:00) 北京,香港,珀斯,新加坡,台北</option>

            <option value="-12" <if condition="$siteRules.group_end_time_zone_api eq -12">selected</if>>GMT -12:00) Eniwetok, Kwajalein</option>

            <option value="-11" <if condition="$siteRules.group_end_time_zone_api eq -11">selected</if>>(GMT -11:00) Midway Island, Samoa</option>

            <option value="-10" <if condition="$siteRules.group_end_time_zone_api eq -10">selected</if>>(GMT -10:00) Hawaii</option>

            <option value="-9" <if condition="$siteRules.group_end_time_zone_api eq -9">selected</if>>(GMT -09:00) Alaska</option>

            <option value="-8" <if condition="$siteRules.group_end_time_zone_api eq -8">selected</if>>(GMT -08:00) Pacific Time (US &amp; Canada), Tijuana</option>

            <option value="-7" <if condition="$siteRules.group_end_time_zone_api eq -7">selected</if>>(GMT -07:00) Mountain Time (US &amp; Canada), Arizona</option>

            <option value="-6" <if condition="$siteRules.group_end_time_zone_api eq -6">selected</if>>(GMT -06:00) Central Time (US &amp; Canada), Mexico City</option>

            <option value="-5" <if condition="$siteRules.group_end_time_zone_api eq -5">selected</if>>(GMT -05:00) Eastern Time (US &amp; Canada), Bogota, Lima, Quito</option>

            <option value="-4" <if condition="$siteRules.group_end_time_zone_api eq -4">selected</if>>(GMT -04:00) Atlantic Time (Canada), Caracas, La Paz</option>

            <option value="-3.5" <if condition="$siteRules.group_end_time_zone_api eq -3.5">selected</if>>(GMT -03:30) Newfoundland</option>

            <option value="-3" <if condition="$siteRules.group_end_time_zone_api eq -3">selected</if>>(GMT -03:00) Brassila, Buenos Aires, Georgetown, Falkland Is</option>

            <option value="-2" <if condition="$siteRules.group_end_time_zone_api eq -2">selected</if>>(GMT -02:00) Mid-Atlantic, Ascension Is., St. Helena</option>

            <option value="-1" <if condition="$siteRules.group_end_time_zone_api eq -1">selected</if>>(GMT -01:00) Azores, Cape Verde Islands</option>

            <option value="1" <if condition="$siteRules.group_end_time_zone_api eq 1">selected</if>>(GMT +01:00) Amsterdam, Berlin, Brussels, Madrid, Paris, Rome</option>

            <option value="2" <if condition="$siteRules.group_end_time_zone_api eq 2">selected</if>>(GMT +02:00) Cairo, Helsinki, Kaliningrad, South Africa</option>

            <option value="3" <if condition="$siteRules.group_end_time_zone_api eq 3">selected</if>>(GMT +03:00) Baghdad, Riyadh, Moscow, Nairobi</option>

            <option value="3.5" <if condition="$siteRules.group_end_time_zone_api eq 3.5">selected</if>>(GMT +03:30) Tehran</option>

            <option value="4" <if condition="$siteRules.group_end_time_zone_api eq 4">selected</if>>(GMT +04:00) Abu Dhabi, Baku, Muscat, Tbilisi</option>

            <option value="4.5" <if condition="$siteRules.group_end_time_zone_api eq 4.5">selected</if>>(GMT +04:30) Kabul</option>

            <option value="5" <if condition="$siteRules.group_end_time_zone_api eq 5">selected</if>>(GMT +05:00) Ekaterinburg, Islamabad, Karachi, Tashkent</option>

            <option value="5.5" <if condition="$siteRules.group_end_time_zone_api eq 5.5">selected</if>>(GMT +05:30) Bombay, Calcutta, Madras, New Delhi</option>

            <option value="5.75" <if condition="$siteRules.group_end_time_zone_api eq 5.75">selected</if>>(GMT +05:45) Katmandu</option>

            <option value="6" <if condition="$siteRules.group_end_time_zone_api eq 6">selected</if>>(GMT +06:00) Almaty, Colombo, Dhaka, Novosibirsk</option>

            <option value="6.5" <if condition="$siteRules.group_end_time_zone_api eq 6.5">selected</if>>(GMT +06:30) Rangoon</option>

            <option value="7" <if condition="$siteRules.group_end_time_zone_api eq 7">selected</if>>(GMT +07:00) Bangkok, Hanoi, Jakarta</option>

            <option value="9" <if condition="$siteRules.group_end_time_zone_api eq 9">selected</if>>(GMT +09:00) Osaka, Sapporo, Seoul, Tokyo, Yakutsk</option>

            <option value="9.5" <if condition="$siteRules.group_end_time_zone_api eq 9.5">selected</if>>(GMT +09:30) Adelaide, Darwin</option>

            <option value="10" <if condition="$siteRules.group_end_time_zone_api eq 10">selected</if>>(GMT +10:00) Canberra, Guam, Melbourne, Sydney, Vladivostok</option>

            <option value="11" <if condition="$siteRules.group_end_time_zone_api eq 11">selected</if>>(GMT +11:00) Magadan, New Caledonia, Solomon Islands</option>

            <option value="12" <if condition="$siteRules.group_end_time_zone_api eq 12">selected</if>>(GMT +12:00) Auckland, Wellington, Fiji, Marshall Island</option>

        </select>

        </td>

	</tr>

    <tr class="collect_type_1 none">
		<td class="tRight">&nbsp;</td>
		<td class="tLeft">
        	{$Think.lang.TIME_ZONE_NOTIC}
        </td>
	</tr>

	<tr class="collect_type_1 none">
		<td class="tRight">{$Think.lang.GROUP_SHOP_PRICE_API}：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_price_api]" id="group_shop_price_api" size="60" value='{$siteRules.group_shop_price_api}' /></td>
	</tr>

	<tr class="collect_type_1 none">
		<td class="tRight">{$Think.lang.GROUP_MARKET_PRICE_API}：</td>
		<td class="tLeft"><input type="text" name="api[group_market_price_api]" id="group_market_price_api" size="60" value='{$siteRules.group_market_price_api}' /></td>
	</tr>

	<tr class="collect_type_1 none">
		<td class="tRight">已购买人数(GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_bought_api]" id="group_bought_api" size="60" value='{$siteRules.group_bought_api}'/></td>
	</tr>
	<tr class="collect_type_1 none">
		<td class="tRight">团购提示(GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_brief_api]" id="group_brief_api" size="60" value='{$siteRules.group_brief_api}'/></td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">团购详细(GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_content_api]" id="group_content_api" size="60" value='{$siteRules.group_content_api}'/></td>
	</tr>
	<tr class="collect_type_1 none">
		<td class="tRight">团购商圈(GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_area_api]" id="group_area_api" size="60" value='{$siteRules.group_area_api}'/></td>
	</tr>
	<tr class="collect_type_1 none">
		<td class="tRight">&nbsp;</td>
		<td class="tLeft">当API中的商圈不在商家列表中时，使用此设置</td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">商家对像(GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_api]" id="group_shop_api" size="60" value='{$siteRules.group_shop_api}'/></td>
	</tr>
	<tr class="collect_type_1 none">
		<td class="tRight">&nbsp;</td>
		<td class="tLeft">当API中的没有商家列表对像时，以下设置可使用GOODS.*</td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">商家名称(SHOP.*/GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_name_api]" id="group_shop_name_api" size="60" value='{$siteRules.group_shop_name_api}'/></td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">商家地址(SHOP.*/GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_addr_api]" id="group_shop_addr_api" size="60" value='{$siteRules.group_shop_addr_api}'/></td>
	</tr>
	<tr class="collect_type_1 none">
		<td class="tRight">商家商圈(SHOP.*/GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_area_api]" id="group_shop_area_api" size="60" value='{$siteRules.group_shop_area_api}'/></td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">商家电话(SHOP.*/GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_tel_api]" id="group_shop_tel_api" size="60" value='{$siteRules.group_shop_tel_api}'/></td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">地图经度(SHOP.*/GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_lon_api]" id="group_shop_lon_api" size="60" value='{$siteRules.group_shop_lon_api}'/></td>
	</tr>
    <tr class="collect_type_1 none">
		<td class="tRight">地图纬度(SHOP.*/GOODS.*)：</td>
		<td class="tLeft"><input type="text" name="api[group_shop_lat_api]" id="group_shop_lat_api" size="60" value='{$siteRules.group_shop_lat_api}'/></td>
	</tr>
</table>

<div style="padding:20px 0 0 130px;">

	<input type="hidden" value="{$vo.id}" name="id" id="site-id"/>

	<input type="submit" value="{$Think.lang.SAVE_DATA}" class="button small">

	<input type="reset" class="button small" onclick="resetEditor()" value="{$Think.lang.RESET_DATA}">

</div>

</div>

</form>

</div>

</div>
<script type="text/javascript">
jQuery(function($){
	$("#is_all_city").change(function(){
		if(this.checked)
		{
			$(".site_city").each(function(i){
				this.setAttribute('sort',this.value);
				this.value = '';
			});
		}
		else
		{
			$(".site_city").each(function(i){
				this.value = this.getAttribute('sort');
			});
		}
		$(".site_city").attr({"disabled":this.checked});
	});
});
</script>
